package com.apkfuns.jsbridge.view;

import com.apkfuns.jsbridge.util.TakePhotoResult;
import com.apkfuns.jsbridge.util.WebEvent;
import com.apkfuns.jsbridge.view.base.BaseAbility;
import com.apkfuns.jsbridge.view.slice.CustomWebViewAbilitySlice;
import ohos.aafwk.content.Intent;
import ohos.agp.window.dialog.ToastDialog;

public class CustomWebViewAbility extends BaseAbility  implements WebEvent {

    @Override
    public void onStart(Intent intent) {
        super.onStart(intent);
        super.setMainRoute(CustomWebViewAbilitySlice.class.getName());
    }

    @Override
    public void takePhoto(TakePhotoResult result) {

        new ToastDialog(getContext())
                .setText("CustomWebViewAbility takePhoto")
                .show();
    }
}
